package com.gssuren.demo.dao;

import com.gssuren.demo.datasource.annotaion.DataSource;
import com.gssuren.demo.model.User;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface UserDao {

    int deleteByPrimaryKey(Integer id);

    @DataSource("slave2")
    int insert(User record);

    int insertSelective(User record);

    User selectByPrimaryKey(Integer id);

    List<User> selectByName(String memberName);

    int updateByPrimaryKeySelective(User record);

    int updateByPrimaryKey(User record);
}